package shop.category;

import java.io.File;
import java.util.*;

import shop.category.product.Product;

public class Category {

	File path = null;

	public Category(File path) {
		this.path = path;
	}

	public Map<String, Map<Integer, Map<String, String>>> getMapOfCategory() {
		Map<String, Map<Integer, Map<String, String>>> map = new HashMap<String, Map<Integer, Map<String, String>>>();

		String[] listOfFile = path.list();
		for (String file : listOfFile)
			map.put(file,
					new Product(new File(path + "/" + file)).getMapOfProduct());

		return map;
	}

}
